module dequeueMuxer16 (
    input wire clk,
    input wire rst,
    input wire dequeue_vld_1,
    input wire dequeue_vld_2,
    input wire dequeue_vld_3,
    input wire dequeue_vld_4,
    input wire dequeue_vld_5,
    input wire dequeue_vld_6,
    input wire dequeue_vld_7,
    input wire dequeue_vld_8,
    input wire dequeue_vld_9,
    input wire dequeue_vld_10,
    input wire dequeue_vld_11,
    input wire dequeue_vld_12,
    input wire dequeue_vld_13,
    input wire dequeue_vld_14,
    input wire dequeue_vld_15,
    input wire dequeue_vld_16,
    input wire [5:0] dequeue_priority_1,
    input wire [5:0] dequeue_priority_2,
    input wire [5:0] dequeue_priority_3,
    input wire [5:0] dequeue_priority_4,
    input wire [5:0] dequeue_priority_5,
    input wire [5:0] dequeue_priority_6,
    input wire [5:0] dequeue_priority_7,
    input wire [5:0] dequeue_priority_8,
    input wire [5:0] dequeue_priority_9,
    input wire [5:0] dequeue_priority_10,
    input wire [5:0] dequeue_priority_11,
    input wire [5:0] dequeue_priority_12,
    input wire [5:0] dequeue_priority_13,
    input wire [5:0] dequeue_priority_14,
    input wire [5:0] dequeue_priority_15,
    input wire [5:0] dequeue_priority_16,
    input wire [9:0] dequeue_value_1,
    input wire [9:0] dequeue_value_2,
    input wire [9:0] dequeue_value_3,
    input wire [9:0] dequeue_value_4,
    input wire [9:0] dequeue_value_5,
    input wire [9:0] dequeue_value_6,
    input wire [9:0] dequeue_value_7,
    input wire [9:0] dequeue_value_8,
    input wire [9:0] dequeue_value_9,
    input wire [9:0] dequeue_value_10,
    input wire [9:0] dequeue_value_11,
    input wire [9:0] dequeue_value_12,
    input wire [9:0] dequeue_value_13,
    input wire [9:0] dequeue_value_14,
    input wire [9:0] dequeue_value_15,
    input wire [9:0] dequeue_value_16,
    output wire dequeue_vld,
    output wire [9:0] dequeue_value
);
    wire [3:0] dequeue_vld_group;
    wire [5:0] dequeue_priority_group [0:3];
    wire [9:0] dequeue_value_group [0:3];

    
    //第一层仲裁器
    dequeueMuxer4 muxer1(.clk(clk), .rst(rst),
                        .dequeue_vld_1(dequeue_vld_1), .dequeue_priority_1(dequeue_priority_1), .dequeue_value_in_1(dequeue_value_1), 
                        .dequeue_vld_2(dequeue_vld_2), .dequeue_priority_2(dequeue_priority_2), .dequeue_value_in_2(dequeue_value_2), 
                        .dequeue_vld_3(dequeue_vld_3), .dequeue_priority_3(dequeue_priority_3), .dequeue_value_in_3(dequeue_value_3), 
                        .dequeue_vld_4(dequeue_vld_4), .dequeue_priority_4(dequeue_priority_4), .dequeue_value_in_4(dequeue_value_4), 
                        .dequeue_vld_out(dequeue_vld_group[0]), .dequeue_priority_out(dequeue_priority_group[0]), .dequeue_value_out(dequeue_value_group[0]));
    
    dequeueMuxer4 muxer2(.clk(clk), .rst(rst),
                        .dequeue_vld_1(dequeue_vld_5), .dequeue_priority_1(dequeue_priority_5), .dequeue_value_in_1(dequeue_value_5), 
                        .dequeue_vld_2(dequeue_vld_6), .dequeue_priority_2(dequeue_priority_6), .dequeue_value_in_2(dequeue_value_6), 
                        .dequeue_vld_3(dequeue_vld_7), .dequeue_priority_3(dequeue_priority_7), .dequeue_value_in_3(dequeue_value_7), 
                        .dequeue_vld_4(dequeue_vld_8), .dequeue_priority_4(dequeue_priority_8), .dequeue_value_in_4(dequeue_value_8), 
                        .dequeue_vld_out(dequeue_vld_group[1]), .dequeue_priority_out(dequeue_priority_group[1]), .dequeue_value_out(dequeue_value_group[1]));

    dequeueMuxer4 muxer3(.clk(clk), .rst(rst),
                        .dequeue_vld_1(dequeue_vld_9), .dequeue_priority_1(dequeue_priority_9), .dequeue_value_in_1(dequeue_value_9), 
                        .dequeue_vld_2(dequeue_vld_10), .dequeue_priority_2(dequeue_priority_10), .dequeue_value_in_2(dequeue_value_10), 
                        .dequeue_vld_3(dequeue_vld_11), .dequeue_priority_3(dequeue_priority_11), .dequeue_value_in_3(dequeue_value_11), 
                        .dequeue_vld_4(dequeue_vld_12), .dequeue_priority_4(dequeue_priority_12), .dequeue_value_in_4(dequeue_value_12), 
                        .dequeue_vld_out(dequeue_vld_group[2]), .dequeue_priority_out(dequeue_priority_group[2]), .dequeue_value_out(dequeue_value_group[2]));

    dequeueMuxer4 muxer4(.clk(clk), .rst(rst),
                        .dequeue_vld_1(dequeue_vld_13), .dequeue_priority_1(dequeue_priority_13), .dequeue_value_in_1(dequeue_value_13), 
                        .dequeue_vld_2(dequeue_vld_14), .dequeue_priority_2(dequeue_priority_14), .dequeue_value_in_2(dequeue_value_14), 
                        .dequeue_vld_3(dequeue_vld_15), .dequeue_priority_3(dequeue_priority_15), .dequeue_value_in_3(dequeue_value_15), 
                        .dequeue_vld_4(dequeue_vld_16), .dequeue_priority_4(dequeue_priority_16), .dequeue_value_in_4(dequeue_value_16), 
                        .dequeue_vld_out(dequeue_vld_group[3]), .dequeue_priority_out(dequeue_priority_group[3]), .dequeue_value_out(dequeue_value_group[3]));
    //第二组仲裁器
    dequeueMuxer4 muxer(.clk(clk), .rst(rst),
                        .dequeue_vld_1(dequeue_vld_group[0]), .dequeue_priority_1(dequeue_priority_group[0]), .dequeue_value_in_1(dequeue_value_group[0]), 
                        .dequeue_vld_2(dequeue_vld_group[1]), .dequeue_priority_2(dequeue_priority_group[1]), .dequeue_value_in_2(dequeue_value_group[1]), 
                        .dequeue_vld_3(dequeue_vld_group[2]), .dequeue_priority_3(dequeue_priority_group[2]), .dequeue_value_in_3(dequeue_value_group[2]), 
                        .dequeue_vld_4(dequeue_vld_group[3]), .dequeue_priority_4(dequeue_priority_group[3]), .dequeue_value_in_4(dequeue_value_group[3]), 
                        .dequeue_vld_out(dequeue_vld), .dequeue_priority_out(), .dequeue_value_out(dequeue_value));
endmodule